package com.adups.monitor.task;

import java.util.Date;

import org.mybatis.spring.SqlSessionFactoryBean;
import org.mybatis.spring.mapper.MapperScannerConfigurer;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.jdbc.datasource.DataSourceTransactionManager;
import org.springframework.stereotype.Component;

import com.adups.monitor.config.EMailConfig;
import com.adups.monitor.config.MonitorParamConfig;
import com.adups.monitor.service.StatOTAService;
import com.alibaba.druid.pool.DruidDataSource;

@Component("projectMonitorTask")
public class ProjectMonitorTask {

private Logger logger = LoggerFactory.getLogger(getClass());
	
	@Autowired
	private StatOTAService statOTAService;
	
	public void projecgMonitorJob(){
	
		try{			
			statOTAService.myMonitorJob();
			logger.info("任务执行成功。time: " + new Date());
		}catch (Exception e){
			e.printStackTrace();
			logger.info("任务执行失败。time: " + new Date());
		}
	}
}
